﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Linq.Expressions;
using System.Text;
using STF.OrangeDog.Model;
using System.Threading.Tasks;

namespace STF.OrangeDog.IRepository
{
    public interface IBaseDal<T> where  T:BaseModel,new()
    {
        Task<int> AddModelAsync(T model);
        Task<int> EditModelAsync(T model);
        Task<int> RemoveModelAsync(T model);
        Task<IEnumerable<T>> GetAllAsync();
        Task<IEnumerable<T>> GetDataByChooseAsync(Expression<Func<T, bool>> whereLambda);
        Task<T> GetDataByIdAsync(int id);
    }
}
